package ioc;

import javax.annotation.Resource;

import org.springframework.stereotype.Component;

@Component("leader")
public class Leader {

	
	
	@Resource(name="wt")
	private Waiter wtr;
	

//	@Resource(name="wt")
//	public void setWtr(Waiter wtr) {
//		System.out.println("Leader的setWtr()");
//		this.wtr = wtr;
//	}


	public Waiter getWtr() {
		return wtr;
	}

	public Leader() {	
		System.out.println("Leader()");
	}



	@Override
	public String toString() {
		return "Leader [wtr=" + wtr + "]";
	}

	
	
	
	
}










